package people.paper.tv.activity.home.modual.rmrb.model;

import com.coocaa.app.support.net.Callback;
import com.coocaa.app.support.net.Result;

import java.util.List;

import people.paper.tv.activity.home.HomeFragment;
import people.paper.tv.activity.home.model.MainDataObject;

/**
 * The interface Rmrb model.
 */
public interface RMRBModel extends HomeFragment.FragmentModel {

    String formatDate(long time);

    /**
     * 获取从第day天前的报纸内容
     *
     * @param day      第几天前，今天=0，昨天=-1，一次类推
     * @param callback the callback
     */
    void getPaper(int day, Callback<Result<List<MainDataObject.RMRBObject>>> callback);

    /**
     * Gets news title.
     *
     * @param date     the date
     * @param layoutId the layout id
     * @param newsId   the news id
     * @param callback the callback
     */
    void getNewsContent(String date, String layoutId, String newsId, Callback<Result<String>> callback);

    class SupportDay {
        public String name;
        public long timestamp;
    }

    List<SupportDay> getSupportDays();
}
